import { defineStore } from "pinia";

const useApp = defineStore('appStore', {
    state() {
        return {
            count: 0,
            name: '李华'
        }
    },
    getters: {
        updateCount(state) {
            return state.count * 10
        }
    },
    actions: {
        updateName(name: string) {
            this.name = name
        }
    }
})

export default useApp